package QianFeng11.AOP;

import java.io.InputStream;

public class AOPTest {

    public static void main(String[] args) {
        //读取配置文件
        InputStream in = Thread.currentThread().getContextClassLoader()
                .getResourceAsStream("QianFeng11/AOP/bean.properties");
        //创建Bean的工厂对象
        BeanFactory beanFactory = new BeanFactory(in);
        //获取代理对象
        ProxyFactoryBean proxyFactoryBean = (ProxyFactoryBean) beanFactory.getBean("bean");
        IManager proxy = (IManager) proxyFactoryBean.getProxy();
        proxy.add("我是一只猫");
    }
}
